#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
	int year = 0;
	int month = 0;
	int day = 0;
	scanf("%4d%2d%2d",&year,&month,&day);
	printf("%4d\n",year);
	printf("%2d\n",month);
	printf("%2d\n",day);
	return 0;
}